use std::sync::Arc;

use tokio::sync::Mutex;
use tracing::info;

use crate::app_state::AppState;
use crate::huang_ling_task::huang_ling_task;
use anyhow::Result;

pub async fn back_task(app_state: Arc<Mutex<AppState>>) ->Result<()> {
    info!("后台任务开始执行");
    huang_ling_task(app_state.clone()).await?;
    info!("后台任务执行结束");
    Ok(())
}
